/*
 * @Author: 焦质晔
 * @Date: 2019/6/20
 * @Last Modified by: mikey.zhaopeng
 * @Last Modified time: 2019-12-15 15:21:28
 */
import axios from '@/api/fetch';
import SERVER from '@/api/server';

// 列表查询
export const getList = (params) => axios.post(`${SERVER.CMSCLOUD_CHANNEL}/message/dealerAttach/queryListBySapAudit`, params)
// 查询详情
export const getDetail = (params) => axios.get(`${SERVER.CMSCLOUD_CHANNEL}/message/dealerAttach/queryListBySapAuditEnergy`, { params })
//查询新能源SAP
export const getSap = (params) => axios.get(`/api/datacenter/message/dealerAttach/queryListBySapAuditSap`, { params })

//  导出
export const exportList = (params) => axios.post(`${SERVER.CMSCLOUD_CHANNEL}/message/dealerAttach/queryListBySapAuditExport`, params, { responseType: 'blob' })
// 保存
export const postSave = (params) => axios.post(`${SERVER.CMSCLOUD_CHANNEL}/message/dealerAttach/saveSapAuditEnergy`, params)
export const getDetails = (params) => axios.get(`${SERVER.CMSCLOUD_CHANNEL}/message/dealerAttach/${params.id}`,{params});
// 获取事业部
export const getDeptList = (params) => axios.get(`${SERVER.DMSCLOUD_BASEDATA}/org/getOrgByOrgType4cms`, { params })
